The present invention relates to computer-implemented methods for determining the envelope of a brush with respect to a trajectory.
Computer painting programs allow the user to "paint" on an electronic image with an onscreen "brush" controlled by an input device such as a mouse. The user may typically select from among a variety of brush shapes, e.g., circle, square, or single pixel. In programs using "brush extrusion," the user drags a brush defined by a bitmap (e.g., a bitmap of a filled square) along a trajectory (i.e., a sequence of points), leaving the image of the brush at each point in the trajectory. In some programs which use brush extrusion, the size and shape of the brush may vary along the trajectory.
A In the so-called "vector brushstroke" approach, the brush is a closed shape, which may be defined, for example, by a sequence of points connected by line segments. When the user draws a stroke by dragging the brush along a trajectory, the program computes from the brush and the trajectory a stroke envelope intended to correspond to the envelope of the stroke. The stroke envelope may then be filled with a color or a texture. Some programs using the vector brushstroke approach allow the horizontal and/or vertical scale of the brush to vary along the trajectory.
Some paint programs allow the user to paint using other input devices, such as drawing tablets. When the user depresses the end of a stylus at a particular location on the drawing tablet, the x and y coordinates of the depression are communicated to the paint program. Some tablets can also detect and transmit the pressure with which the user presses the stylus on the tablet, the angle between the stylus and the tablet (referred to as tilt or elevation), and the angle at which the stylus is rotated relative to the plane of the tablet (referred to as azmuth). Some paint programs vary the size and rotation of the brush in proportion to the pressure, tilt, and azmuth of the stylus.